from pydantic import BaseModel, Field


class InRoom(BaseModel):
    room: str = Field(..., description="房间名", example="客厅")


class OutRoom(BaseModel):
    room: str = Field(..., description="服务器返回的房间名", example="客厅")
    time: float = Field(..., description="服务器返回的时间戳", example=1635247642749)


class InColor(BaseModel):
    color: str = Field(..., description="16进制颜色代码", example="#ff1234")


class OutColor(BaseModel):
    color: str = Field(..., description="服务器返回的颜色代码", example="#ff1234")
    time: float = Field(..., description="服务器返回的时间戳", example=1635247642749)
